#include <cmath>
#include "DUtils.hpp"
#include "DGlobals.hpp"

namespace Distillate {

DUtils::DUtils() {
	//ctor
}

DUtils::~DUtils() {
	//dtor
}

float DUtils::computeVelocity(float Velocity, float Acceleration, float Drag, float Max) {
	/*
	    if(Acceleration != 0)
	        Velocity += Acceleration*FlxG.elapsed;
	    else if(Drag != 0)
	    {
	        var d:Number = Drag*FlxG.elapsed;
	        if(Velocity - d > 0)
	            Velocity -= d;
	        else if(Velocity + d < 0)
	            Velocity += d;
	        else
	            Velocity = 0;
	    }
	    if((Velocity != 0) && (Max != 10000))
	    {
	        if(Velocity > Max)
	            Velocity = Max;
	        else if(Velocity < -Max)
	            Velocity = -Max;
	    }

	    return Velocity;
	*/
	return 0.0f;
}

DPoint* DUtils::rotatePoint(float X, float Y, float PivotX, float PivotY, float  Angle, DPoint *P) {
	return NULL;
}

}

